package com.yyh.javase1;
/*模拟trim()方法的实现，忽略字符串中前后的空格*/
public class Test5 {
    public static void main(String[] args) {
        String str = "  hello world  ";
        String s1 = str.trim();
        System.out.println(s1);
    }
}
